<#import "/spring.ftl" as spring />
<#import "/inspector-time-macros.ftl" as imacro />

<html>
<head>
	<title>overrideRecurringRule.ftl</title>
	
</head>

<body>

<div id="content">

	<h1>OVERRIDE TIMESLOT</h1>
		
	<p>You have clicked on a specific date within a <b>recurring</b> timeslot: ${command.startDate.time?string("MMM dd, yyyy")}</p>
	
	<p>To change your availability on this day only, you can adjust the fields below to override it with a new non-recurring timeslot. To edit the details for all times going forward, <a href="editRecurring.html?inspectorId=${RequestParameters.inspectorId}&ruleId=${RequestParameters.ruleId}">edit the recurring timeslot</a> instead.</p>
	
	<@imacro.listErrors "command" />
	
	<form method="post">

	<input type="hidden" name="inspectorId" value="${RequestParameters.inspectorId}" />
	<input type="hidden" name="originalRuleId" value="${RequestParameters.ruleId}" />
	<input type="hidden" name="frequencyType" value="SINGLE_DAY" />
	
	<div class="databoxWrapper">
		<div class="databox">
		<h1>RULE DETAILS</h1>
			<table class="databoxLabelTable2Cols">
			<tr>
				<th>START TIME:</td>
				<td class="databoxFreeForm"><@spring.formSingleSelect "command.startHour", hours/>:<@spring.formSingleSelect "command.startMinute", minutes/></td>
			</tr>
			<tr>
				<th>END TIME:</td>
				<td class="databoxFreeForm"><@spring.formSingleSelect "command.endHour", hours/>:<@spring.formSingleSelect "command.endMinute", minutes/></td>
			</tr>
			<tr>
				<th>ARE YOU AVAILABLE IN THIS TIMESLOT?</td>
				<td><@imacro.singleRadioButton "command.available"," YES" " NO" "&nbsp;&nbsp;" "class=radio"/></td>
			</tr>
		</table>
		</div>
	</div>
	
	<p>Note: You are adding a new timeslot. No changes will be made to the details of your existing recurring timeslot.</p>
	
	<input type="submit" value="ADD TIMESLOT" class="formButton"/>&nbsp;&nbsp;&nbsp;<a href="viewScheduleRules.html?inspectorId=${RequestParameters.inspectorId}" class="formLink">-CANCEL-</a>
	
	</form>

</div>
</body>
</html>